class Solution(object):
    def createTargetArray(self, nums, index):
        target = []
        n = len(nums)
        for i in range(n):
            target.insert(index[i], nums[i])
        return target